Automatically check xen's public headers for C++ pitfalls.
authorTim Deegan <tim@xen.org>
Fri, 27 Feb 2015 09:46:34 +0000 (09:46 +0000)
committerTim Deegan <tim@xen.org>
Fri, 27 Feb 2015 09:46:34 +0000 (09:46 +0000)
commita7721bee28d7a130abd0e316da64a6c995130cee
tree1f1b209d125ef44307a24e6ecd446820b9c8ef9b
parentbefe0a0da90d7ac063fd8b5891c7d0caeeeefa5f
Automatically check xen's public headers for C++ pitfalls.

Add a check, like the existing check for non-ANSI C in the public
headers, that runs the public headers through a C++ compiler to
flag non-C++-friendly constructs.

Unlike the ANSI C check, we accept GCC-isms (gnu++98), and we also
check various tools-only headers.

Also tidy up the runes for these checks to be a bit more readable.

io/ring.h uses 'private' as a field name, which is a keyword in C++;
this patch doesn't change that.  Instead the check works around it.

Reported-by: Razvan Cojocaru <rcojocaru@bitdefender.com>
Signed-off-by: Tim Deegan <tim@xen.org>
Acked-by: Jan Beulich <JBeulich@suse.com>
Tested-by: Don Slutz <dslutz@verizon.com>
.gitignore
config/StdGNU.mk
config/SunOS.mk
xen/include/Makefile
xen/include/public/xsm/flask_op.h